package org.example.Service;

import org.example.mapper.ShippingInfoMapper;
import org.example.pojo.ShippingInfo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class ShippingInfoServiceImpl implements ShippingInfoService{
    @Autowired
    private ShippingInfoMapper shippingInfoMapper;
    @Override
    public List<ShippingInfo> selectShippingInfos() {
        return shippingInfoMapper.selectShippingInfos();
    }

    @Override
    public ShippingInfo selectShippingInfoByID(Integer id) {
        return shippingInfoMapper.selectShippingInfoByID(id);
    }

    @Override
    public ShippingInfo selectShippingInfoByOrderID(Integer id) {
        return shippingInfoMapper.selectShippingInfoByOrderID(id);
    }

    @Override
    public int insertShippingInfo(ShippingInfo shippingInfo) {
        return shippingInfoMapper.insertShippingInfo(shippingInfo);
    }

    @Override
    public int updateShippingInfo(ShippingInfo shippingInfo) {
        return shippingInfoMapper.updateShippingInfo(shippingInfo);
    }

    @Override
    public int deleteShippingInfo(Integer id) {
        return shippingInfoMapper.deleteShippingInfo(id);
    }
}
